home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / os2 / fm2_214.zip / uninstal.cmd < prev    next >
OS/2 REXX Batch file  |  1994-08-05  |  2KB  |  69 lines

  1. /*
  2.  * FM/2 2.x deinstallation program copyright (c) 1994 by M. Kimes
  3.  *
  4.  * This program removes the FM/2 folder and any OS2USER.INI records
  5.  * for FM/2.
  6.  *
  7.  * For unattended use, remove the lines marked with "NOTE:" below and
  8.  * see note at bottom of program.
  9.  */
  10.  
  11. '@Echo off'
  12. 'cls'
  13. 'echo  ┌───────────────────────────────────────────────────────────────────┐'
  14. 'echo  │                 FM/2 2.x Deinstallation Program                   │'
  15. 'echo  │             FM/2 is copyright (c) 1993/94 by M. Kimes             │'
  16. 'echo  │                       All rights reserved                         │'
  17. 'echo  └───────────────────────────────────────────────────────────────────┘'
  18.  
  19. /* see if we might be in the right directory... */
  20.  
  21. rc = stream('fm3.exe','c','query exists')
  22. if rc = '' then
  23. do
  24.   say 'Sorry, FM3.EXE not found.  Must not be right directory.  Terminating.'
  25.   exit
  26. end
  27.  
  28. /* tell user what we're doing, give him a chance to hit CTRL-C */
  29.  
  30. say ''
  31. say ' **WARNING:  This program uninstalls FM/2.'
  32. say ''
  33.  
  34.  
  35. /* NOTE:  remove following 3 lines for unattended use... */
  36. say 'Press [Enter] (or CTRL-C then [Enter] to abort).'
  37. Pull dummy .
  38. say ''
  39.  
  40.  
  41. /* load rexx utility functions */
  42.  
  43. call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  44. call SysLoadFuncs
  45.  
  46. say 'Working...'
  47.  
  48. /* remove FM/2 folder object */
  49. call SysDestroyObject "<FM3_Folder>"
  50.  
  51. /* remove all FM/2-related information from user ini file */
  52. call SysIni 'USER', 'FM/2'
  53. call SysIni 'USER', 'FM2'
  54.  
  55. /* remove fm2.cmd file if found on PATH */
  56. fm2cmd = SysSearchPath('PATH', 'FM2.CMD')
  57. if fm2cmd \= '' then
  58.   'del 'fm2cmd
  59.  
  60. /* done */
  61.  
  62. say ''
  63. /* NOTE:  remove following 3 lines for unattended use... */
  64. say "Delete programs and you're done (DEL *).  Press [Enter]."
  65. Pull dummy .
  66. say ''
  67.  
  68. /* NOTE:  Add 'ECHO Y | DEL *' for unattended use... */
  69.